package com.zsj.mode.responsibilityChain;

/**
 * @Author zsj
 * @Version 1.0
 * @Date 2023/11/9 8:46
 * @Description
 */
public class Client {

    /**
     * 发送请求的
     *
     * @param args
     */
    public static void main(String[] args) {

        PurchaseRequest request = new PurchaseRequest();
        request.setPrice(5000);

        PurchaseRequest request2 = new PurchaseRequest();
        request2.setPrice(5002);
        Handler department = new Department();
        Handler school = new School();
        department.setHeader(school);
        department.processRequest(request);
        department.processRequest(request2);
    }
}
